package com.jrx.anytxn.customer.service;

import com.jrx.anytxn.common.exception.TxnBizException;
import com.jrx.anytxn.common.exception.TxnException;
import com.jrx.anytxn.customer.dto.creditinfo.CreditInfoRes;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeResultReq;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeBaseRes;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeQueryRes;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeFrozeReq;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeRes;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeUseRes;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitVerifyDto;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerUseLimitFrozeFrozeReq;
import com.jrx.anytxn.customer.dto.customer.medical.CustomerLimitFrozeInfoReq;
import com.jrx.anytxn.customer.entity.CmCustomerLimitFroze;

import java.util.Date;
import java.util.List;

/**
 * 用于信用就医的额度冻结、解冻处理
 */
public interface ICmCustomerLimitFrozeService {

    /**
     * 信用就医额度冻结处理
     * @param cmCustomerLimitFroze
     * @return int
     */
    int limitFreezeInfoInsert(CmCustomerLimitFroze cmCustomerLimitFroze) throws TxnException;

    /**
     * 信用就医额度更新处理
     * @param limitToUnfreeze
     * @return int
     */
    int creditMedicalUpdateByParams(CmCustomerLimitFroze limitToUnfreeze) throws TxnException;

    /**
     * 信用就医额度解冻处理
     * @param  dto
     */
    void creditMedicalVerifyLimit(CustomerLimitVerifyDto dto) throws TxnBizException;

    /**
     * 信用就医额度信息查询
     * @param  record
     * @return List<CmCustomerLimitFroze>
     */
    List<CmCustomerLimitFroze> limitFrozeQuery(CmCustomerLimitFroze record) throws TxnException;

    /**
     * 信用就医额度冻结处理
     * @param req
     * @return CustomerLimitFrozeRes
     */
    CustomerLimitFrozeRes creditMedicalFreeze(CustomerLimitFrozeFrozeReq req) throws TxnException,InterruptedException;

    /**
     * 信用就医额度解冻处理
     * @param req
     * @return CustomerLimitFrozeRes
     */
    CustomerLimitFrozeRes creditMedicalUnfreeze(CustomerLimitFrozeFrozeReq req) throws TxnException,InterruptedException;

    /**
     * 信用就医额度冻结额度占用
     * @param useLimitFrozeReq
     * @return CustomerLimitFrozeUseRes
     */
    CustomerLimitFrozeUseRes creditMedicalUseFrozeLimit(CustomerUseLimitFrozeFrozeReq useLimitFrozeReq) throws TxnException,InterruptedException;

    /**
     * 信用就医额度冻结、解冻结果查询
     * @param queryReq
     * @return CustomerLimitFrozeBaseRes
     */
    CustomerLimitFrozeBaseRes limitFreezeResultQuery(CustomerLimitFrozeResultReq queryReq) throws TxnException;


    /**
     * 信用就医额度信息查询
     * @param queryReq
     * @return CustomerLimitFrozeQueryRes
     */
    CustomerLimitFrozeQueryRes limitFreezeInfoQuery(CustomerLimitFrozeInfoReq queryReq) throws TxnException;


}
